<!DOCTYPE html>
<html>
<head>
    <title><?php echo $title; ?></title>
    <style>
        body { font-family: Arial, sans-serif; margin: 40px; }
        h1 { color: #333; }
        .user-card { border: 1px solid #ddd; padding: 20px; border-radius: 5px; max-width: 500px; }
        .user-field { margin-bottom: 10px; }
        .field-label { font-weight: bold; display: inline-block; width: 100px; }
        a { color: #0066cc; text-decoration: none; }
        a:hover { text-decoration: underline; }
    </style>
</head>
<body>
    <h1><?php echo $title; ?></h1>
    
    <?php if ($user): ?>
    <div class="user-card">
        <div class="user-field">
            <span class="field-label">ID:</span>
            <span><?php echo $user['id']; ?></span>
        </div>
        <div class="user-field">
            <span class="field-label">姓名:</span>
            <span><?php echo $user['name']; ?></span>
        </div>
        <div class="user-field">
            <span class="field-label">邮箱:</span>
            <span><?php echo $user['email']; ?></span>
        </div>
        <div class="user-field">
            <span class="field-label">年龄:</span>
            <span><?php echo $user['age']; ?></span>
        </div>
    </div>
    <?php else: ?>
    <p>未找到用户信息</p>
    <?php endif; ?>
    
    <p>
        <a href="/users">返回用户列表</a> | 
        <a href="/">返回首页</a>
    </p>
</body>
</html>